package com.westdream.action;

import java.io.IOException;

import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import com.westdream.service.MessageService;
import com.westdream.service.impl.MessageServiceImpl;

public class ListMessageAction extends Action {

	@Override
	public String execute(HttpServletRequest request,
			HttpServletResponse response, Object data) throws ServletException,
			IOException {
		MessageService msgService = new MessageServiceImpl();
	    request.setAttribute("MSGS", msgService.queryList());
		return "list";
	}
	
}
